# Author: Kuilin


# names = "kuilin,zihan"
# print(names[0])
users_list = ["kuilin","zihan"]
password_list = [520,1314]
age_list = [20,19]

# ...
# 列表的嵌套
info_list = [["kuilin",520,20],["zihan",1314,19]]

# print(users_list[0])
# print(password_list[0])
# print(age_list[0])
# print(info_list[0])
#
# print(users_list[1])
# print(password_list[1])
# print(age_list[1])
# print(info_list[1]


names =["kuilin","zihan","chen","zhuo"]
# 知识点：slices(切片) 数值是指 values在list中的位置

# 1.正向取值
# list 取值 ”：“右侧的值取不到
print(names[0:3])
# 如果左侧的值是0，即从0开始取值，0可以省略不写
print(names[:3])

# 2.反向取值
# list 取值 ”：“右边的值取不到
print(names[-3:-1])


num = [1,2,3,4,5,6,7,8,9 ]
# 对比range
print(num[:6:2])